There is an extracting device which extracts patterns including a predetermined pattern in which an event and an order at which the event appears, from patterns of events indicated by event data obtained by associating events which actually occur and times at which the events appear. In addition, a pattern obtained by associating an event and an order at which the event occurs is also referred to as an “episode”. In the following description, this pattern is referred to as an “episode” in some cases. An example of an episode is the following episode. For example, there is an episode that, after an event A that “a person A takes a medicine A” and an event B that “the person A takes a medicine B”, an event C that “the person A has a fever”. When the extracting device performs the above extraction using this episode, it is possible to extract episodes including an episode that, after the events A and B appear, the above event C appears. For example, the extracting device can extract an episode that an event D that “the person A takes a medicine C” occurs upon appearance the events A and B and, after the events A, B and D appear, the event C appears. When this episode is extracted by the extracting device, a user of the extracting device can learn that the person A took the medicine C together with the medicine A and the medicine B before the person A has a fever.
Further, an example of the above extracting device is the following extracting device. For example, there is an extracting device which extracts episodes including a predetermined episode by generating a child from a parent in an enumeration tree, and determining whether or not the generated child occurs in a pattern of an event indicated by event data and includes the predetermined pattern. This extracting device first sets an empty episode to which no event is set, to a parent episode which is a root of the enumeration tree, and then performs the following processing to generate an enumeration tree. That is, the extracting device generates a child episode by setting as a child episode an episode obtained by adding an event included in event data to a parent episode. Further, the extracting device generates a child episode again by using a newly generated child episode as a parent episode. Thus, the extracting device repeatedly generates a child episode until a predetermined condition is satisfied.
Patent Literature 1: Japanese Laid-open Patent Publication No. 2001-522095
Patent Literature 2: Japanese Laid-open Patent Publication No. 04-125734
Patent Literature 3: Japanese Laid-open Patent Publication No. 08-6957
However, there is a problem that the extracting device is not able to efficiently extract episodes including a predetermined episode. This extracting device generates a child episode which does not include a predetermined episode in some cases. Hence, the extracting device generates a child episode which is not extracted in some cases. Therefore, the extracting device generates a wasteful child episode. Therefore, the extracting device is not able to efficiently extract episodes.